Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct the skip-waiting-installed.html behavior #7251

Merged
merged 1 commit into from
Sep 4, 2017

Conversation

chromium-wpt-export-bot
Copy link
Collaborator

@chromium-wpt-export-bot chromium-wpt-export-bot commented Sep 4, 2017

According to the latest spec, the skipWaiting promise should be resolved
after 'activate' event is dispatched. This change is from
w3c/ServiceWorker#1065.

Tracing through the spec, skipWaiting() enters "Try Activate".
"Try Activate" invokes "Activate". "Activate" blocks until the final step:
"13. Run the Update Worker State algorithm passing registration’s active
worker and activated as the arguments."

"Update Worker State" queues a task to set ServiceWorker#state to 'activated'.
But in step 10, we have dispatched the 'activate' event. Therefore the order
should be:

  1. 'activate' event handler runs
  2. skipWaiting() promise resolves
  3. ServiceWorker#state is set to 'activated'

So we correct the test case here and delete all the wrong expected files.

BUG=725616

Change-Id: Id0765988c7cdf48f39bb73ccb3fc0cce6ea60949
Reviewed-on: https://chromium-review.googlesource.com/646244
Commit-Queue: Matt Falkenhagen [email protected]
Reviewed-by: Matt Falkenhagen [email protected]
Cr-Commit-Position: refs/heads/master@{#499513}

According to the latest spec, the skipWaiting promise should be resolved
after 'activate' event is dispatched. This change is from
w3c/ServiceWorker#1065.

Tracing through the spec, skipWaiting() enters "Try Activate".
"Try Activate" invokes "Activate". "Activate" blocks until the final step:
"13. Run the Update Worker State algorithm passing registration’s active
worker and activated as the arguments."

"Update Worker State" queues a task to set ServiceWorker#state to 'activated'.
But in step 10, we have dispatched the 'activate' event. Therefore the order
should be:
1. 'activate' event handler runs
2. skipWaiting() promise resolves
3. ServiceWorker#state is set to 'activated'

So we correct the test case here and delete all the wrong expected files.

BUG=725616

Change-Id: Id0765988c7cdf48f39bb73ccb3fc0cce6ea60949
Reviewed-on: https://chromium-review.googlesource.com/646244
Commit-Queue: Matt Falkenhagen <[email protected]>
Reviewed-by: Matt Falkenhagen <[email protected]>
Cr-Commit-Position: refs/heads/master@{#499513}
Copy link
Collaborator

@wpt-pr-bot wpt-pr-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Already reviewed downstream.

@ghost
Copy link

ghost commented Sep 4, 2017

Build PASSED

Started: 2017-09-04 17:07:30
Finished: 2017-09-04 17:16:53

View more information about this build on:

@chromium-wpt-export-bot chromium-wpt-export-bot merged commit 08a200e into master Sep 4, 2017
@chromium-wpt-export-bot chromium-wpt-export-bot deleted the chromium-export-da03debaf1 branch September 4, 2017 17:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants